import { Routes } from '@angular/router';
import { UserListComponent } from './pages/user-list/user-list.component';
import { UserDetailsComponent } from './pages/user-details/user-details.component';
import { EmptyComponent } from './pages/empty/empty.component';
import { ShopComponent } from './pages/shop/shop.component';

export const routes: Routes = [
  {path: '', pathMatch: 'full', redirectTo: 'user'},
  {
    path: 'user', children: [
      {path: '', pathMatch: 'full', redirectTo: 'list'},
      {path: 'list', component: UserListComponent},
      {path: 'details', component: UserDetailsComponent},
    ],
  },
  // 子应用1
  {path: 'shop', children: [{path: '**', component: ShopComponent}]},
  {path: '**', component: EmptyComponent},
];

